CXX = g++
CXXFLAGS = -g -Wall -c
OBJECTS = Logic.o Rules.o Players.o Command.o Card.o driver.o
EXEC = straights 

${EXEC} : ${OBJECTS}
	${CXX} ${OBJECTS} -o ${EXEC}

Logic.o : Logic.cc Logic.h
	${CXX} ${CXXFLAGS} Logic.cc

Rules.o : Rules.cc Rules.h
	${CXX} ${CXXFLAGS} Rules.cc

Players.o : Players.cc Players.h
	${CXX} ${CXXFLAGS} Players.cc

Command.o : Command.cpp Command.h
	${CXX} ${CXXFLAGS} Command.cpp

Card.o : Card.cpp Card.h
	${CXX} ${CXXFLAGS} Card.cpp

driver.o : driver.cc Logic.h 
	${CXX} ${CXXFLAGS} driver.cc

.PHONY: clean install

clean: 
	rm ${OBJECTS} ${EXEC}

install:
	sudo mv ${EXEC} /usr/bin/${EXEC}



